#include <stdio.h>
#include <arpa/inet.h>


int main(int argc, char *argv[])
{
	int num = 0x01020304;
	short a = 0x0102;
	int sum = htonl(num);
	printf("%x\n", sum);
	short b = htons(a);
	printf("%x\n", b);


	printf("%x\n", ntohl(sum));G:\work\linuxNetDemo\demo01


	return 0;
}
